#include "ComponentVisitor.h"
#include "PhysicsComponent.h"
#include "PlayerHealthComponent.h"
#include "..\Generic\KillCounter.h"

ComponentVisitor::ComponentVisitor(void) : m_kill_count(0), m_health(0){}
ComponentVisitor::~ComponentVisitor(void){}

void ComponentVisitor::visitPhysicsComponent(PhysicsComponent* p_physicsComponent)
{
	m_position = p_physicsComponent->getPosition();
}

void ComponentVisitor::visitPlayerHealthComponent(PlayerHealthComponent* p_playerHealthComponent)
{
	m_health = p_playerHealthComponent->getHealth();
}

void ComponentVisitor::visitKillCounter(KillCounter* p_killCounter)
{
	m_kill_count = p_killCounter->getKillCount();
}